Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

3261 coding style regexp #3263

Merged
merged 2 commits into from
Sep 26, 2024

Conversation

robertcheramy
Copy link
Collaborator

Pre-Request Checklist

  • Passes rubocop code analysis (try rubocop --auto-correct)
  • Tests added or adapted (try rake test)
  • Changes are reflected in the documentation
  • User-visible changes appended to CHANGELOG.md

Description

  • Closes: Coding style for regexps in oxidized #3261
  • Activates Rubocop Lint/AmbiguousRegexpLiteral, with exception of the models.
  • The models keep their DSL-Syntax and we accept the ambiguity between regexp and two divisions there - ruby chooses the regexp. For this, we disable warnings in minitest (rake test). Corrects modesls without DSL-Syntax for the prompt.
  • Most of the regexp in oxidized follow the style slashes with inner slashes allowed. Activate rubocop Style/RegexpLiteral with these options and correct the few regexp not following this style.

No documentation in CHANGELOG or the documentation as there is no modification for users or authors, just two new cops were activated, the comments in the code should be enough.

- Closes: ytti#3261
- Activates Rubocop Lint/AmbiguousRegexpLiteral, with exception of the
models.
- The models keep their DSL-Syntax and we accept the ambiguity between
regexp and two divisions there - ruby chooses the regexp. For this, we
disable warnings in minitest (rake test). Corrects modesls without
DSL-Syntax for the prompt.
- Most of the regexp in oxidized follow the style slashes with inner
slashes allowed. Activate rubocop Style/RegexpLiteral with these options
and correct the few regexp not following this style.
@robertcheramy robertcheramy merged commit b585415 into ytti:master Sep 26, 2024
5 checks passed
@robertcheramy robertcheramy deleted the 3261-coding-style-regexp branch September 26, 2024 18:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Coding style for regexps in oxidized
1 participant